A labeling process that assigns labels to pixels of connected components is known as a basic method for processing two-dimensional images. Japanese Laid-Open Patent Publication No. H07-192130 discloses a provisional labeling process of a labeling process that is carried out using a one-dimensional SIMD (Single Instruction stream Multiple Data stream) processor. In the disclosed technique, a process of provisional labeling is carried out on each row in an image in order using the one-dimensional SIMD processor.
Japanese Laid-Open Patent Publication No. 2002-230540 discloses a labeling process carried out in parallel for pixels in a diagonal direction in a pixel array in an input image by a plurality of PEs (processing elements) in a one-dimensional SIMD processor. By processing a plurality of pixels in the diagonal direction in parallel, labeling can be carried out for the pixels that are adjacent of a target pixel and would be connecting to the target pixel before labeling the target pixel. By doing so, effective use is made of the parallel processing ability of the SIMD processor and therefore the processing speed is increased. To realize this method however, even for an image with a resolution of around 200 dpi, a one-dimensional SIMD processor with several thousand PEs are required to scan in the diagonal direction.